home *** CD-ROM | disk | FTP | other *** search
/ PD ROM 1 / PD ROM Volume I - Macintosh Software from BMUG (1988).iso / Stacks / Hyper Utilities / Random Stuff / HyperSleep / card_2930.txt < prev    next >
Encoding:
Text File  |  1988-04-24  |  706 b   |  28 lines

  1. -- card: 2930 from stack: in
  2. -- bmap block id: 5376
  3. -- flags: 4000
  4. -- background id: 2744
  5. -- name: 
  6. ----- HyperTalk script -----
  7. global Timeout
  8. global OldLoc
  9. put the long date into card field "Date"
  10. put the time into card field "Time"
  11. get the MouseLoc
  12. if it = OldLoc then -- Have not moved since last time
  13.   get card field Time -- See it we have timed out
  14.   convert it to seconds
  15.   if it > Timeout then -- Timed out so go to Timeout card
  16.     hide menuBar
  17.     visual effect dissolve slowly
  18.     go to first card of background "Timeout"
  19.   end if
  20. else -- We moved so reset the timer and OldLoc
  21.   put it into OldLoc
  22.   put the time into Timeout
  23.   convert Timeout to seconds
  24.   add 60 to Timeout
  25. end if
  26. pass idle
  27.  
  28.